//
//  MySignUpCell.m
//  didacar
//
//  Created by Yang Yuexia on 15/12/10.
//  Copyright © 2015年 dzmmac. All rights reserved.
//

#import "MySignUpCell.h"
#import "UILabel+Yyx.h"
#import "MyCustomModel.h"
@implementation MySignUpCell

- (void)awakeFromNib {
    self.status.layer.cornerRadius = 2;
    self.status.layer.masksToBounds=YES;
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];
}

-(void)showModel:(MyCustomModel *)myCustomModel
{
    

    if (myCustomModel == nil) {
        return;
    }
    
    self.kilometerTime.text = [NSString stringWithFormat:@"%@人报名",@(myCustomModel.SignUpNum).stringValue];
    
    
    self.startTime.text = myCustomModel.SendTime;
    self.startLocation.text = myCustomModel.StartStation;
    self.endLocation.text = myCustomModel.EndStation;
    
    self.price.attributedText = [self getPrice:myCustomModel.TicketPrice.stringValue leftText:@"约" leftSymbol:@"¥"];
    
    // 报名样式
    if (myCustomModel.isSignUp == 0) {
        [self.status statusWaitRegistration];
    }else{
        [self.status statusRegistration];
    }
    
}

@end
